{% extends 'layout.html' %}
{% block content %}
    <div>
        <div class="container">
            <div class="panel panel-default">
                <div class="panel-heading">
                    <h3 class="panel-title"> 修改用户 </h3>
                </div>
                <div class="panel-body">
                    <!--表单-->
                    <form method="post"><!--action可以不写，因为不写的话提交的是当前地址-->
                        {% csrf_token %}
                        <div class="form-group">
                            <label> 姓名 </label>
                            <input type="text" class="form-control" placeholder="姓名" name="name"
                                   value="{{ row_object.name }}"/>
                            <label> 密码 </label>
                            <input type="text" class="form-control" placeholder="密码" name="pwd"
                                   value="{{ row_object.password }}"/>
                            <label> 年龄 </label>
                            <input type="text" class="form-control" placeholder="年龄" name="age"
                                   value="{{ row_object.age }}"/>
                            <label> 余额 </label>
                            <input type="text" class="form-control" placeholder="余额" name="acc"
                                   value="{{ row_object.account }}"/>
                            <label> 入门时间 </label>
                            <input type="text" class="form-control" placeholder="入门时间" name="time"
                                   value="{{ row_object.create_time|date:"Y-m-d" }}"/>
                            <label> 性别 </label>
                            <input type="text" class="form-control" placeholder="性别" name="gen"
                                   value="{{ row_object.gender }}"/>
                            <label> 部门ID </label>
                            <input type="text" class="form-control" placeholder="部门ID" name="depid"
                                   value="{{ row_object.depart_id }}"/>
                        </div>

                        <button type="submit" class="btn btn-primary"> 提交</button>
                    </form>
                </div>
            </div>
        </div>
    </div>
{% endblock %}
